package com.campus.app.service.impl;

import com.campus.commons.entity.NotificationType;
import com.campus.app.mapper.NotificationTypeMapper;
import com.campus.app.service.NotificationTypesService;
import com.baomidou.mybatisplus.extension.service.impl.ServiceImpl;
import com.campus.commons.utils.Result;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;

import java.util.List;

/**
 * <p>
 * 消息类型 服务实现类
 * </p>
 *
 * @author Rin
 * @since 2021-01-25
 */
@Service
public class NotificationTypeServiceImpl extends ServiceImpl<NotificationTypeMapper, NotificationType> implements NotificationTypesService {
    @Autowired
    private NotificationTypeMapper notificationTypeMapper;
    @Override
    public Result<List<NotificationType>> getAllTypes() {
        return Result.result(notificationTypeMapper.selectList(null));
    }
}
